-
Notifications
You must be signed in to change notification settings - Fork 31
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix FloatingBox
merged refs being overwritten by ref
prop in React 19
#3974
Conversation
✅ Deploy Preview for storybook-navy-digital-mod-uk ready!
To edit notification comments on pull requests, go to your Netlify site configuration. |
e0b7722
to
1362d86
Compare
FloatingBox
merged refs being overwritten by ref
prop in React 19
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
🎉
data-testid="floating-box" | ||
{...attributes.popper} | ||
{...rest} | ||
/* |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Sorry, this is really nitpicky but could we change the comment style to:
//
//
//
When using React 19, ref is a prop and was being overwritten with {...rest}.
Setup functions can be safely abstracted and reused across tests.
1362d86
to
00fe246
Compare
Quality Gate passedIssues Measures |
Related issue
Fixes #3969
Overview
Fixes an issue when using React 19 which adds the
ref
as a prop. This was overwriting the merged refs because it isnull
.Reason
The floating box for the
DatePicker
is positioned incorrectly.Work carried out
ref
issueTest instructions
Follow the reproduction steps in the original issue.
Developer notes
A follow up to this (hopefully tomorrow) will be to replace React Popper with Floating UI.